package cn.demo.text.editor.strategy.menu;

import java.awt.event.ActionListener;

import javax.swing.JMenuItem;
import javax.swing.KeyStroke;

import cn.demo.text.editor.constant.Str;

public class SearchMenuItem extends JMenuItem {
    public SearchMenuItem(ActionListener actionListener) {
        super(Str.SEARCH, null);
        this.addActionListener(actionListener);
        this.setActionCommand(Str.SEARCH);
        this.setFont(new MenuFont());
        this.setAccelerator(KeyStroke.getKeyStroke("control F"));
    }
}
